#import "KeyholeQuakeController.h"
        
#import "KeyholeQuakeModel.h"
#import "KeyholeQuakeCell.h"
#import "Masonry.h"

@interface KeyholeQuakeController () <UICollectionViewDataSource, UICollectionViewDelegate>

@property (nonatomic, strong) UICollectionView *xeroxCollectionView;
@property (nonatomic, strong) NSMutableArray *prismXenonDatas;

@end

@implementation KeyholeQuakeController

- (void)viewWillAppear:(BOOL)animated {
    [super viewWillAppear:animated];
}

- (void)viewDidLoad {
    [super viewDidLoad];

    [self voyageStillnessSetupview];
	[self glistenMagnitudeHummingbirdrequestData];
}


//: 获取数据模型
- (void)glistenMagnitudeHummingbirdrequestData {
	
}

- (void)voyageStillnessSetupview {
    UICollectionViewFlowLayout *undertowPerceptive = [[UICollectionViewFlowLayout alloc] init];
    undertowPerceptive.minimumLineSpacing = 10;
    undertowPerceptive.minimumInteritemSpacing = 10;
    undertowPerceptive.itemSize = CGSizeMake(100, 100);
    undertowPerceptive.scrollDirection = UICollectionViewScrollDirectionVertical;
    
    self.xeroxCollectionView = [[UICollectionView alloc] initWithFrame:self.view.bounds collectionViewLayout:undertowPerceptive];
    self.xeroxCollectionView.backgroundColor = UIColor.clearColor;
    self.xeroxCollectionView.delegate = self;
    self.xeroxCollectionView.dataSource = self;
    self.xeroxCollectionView.showsHorizontalScrollIndicator = NO;
    self.xeroxCollectionView.showsVerticalScrollIndicator = NO;
    [self.xeroxCollectionView registerClass:[KeyholeQuakeCell class] forCellWithReuseIdentifier:NSStringFromClass([KeyholeQuakeCell class])];
    
    [self.view addSubview:self.xeroxCollectionView];
    [self.xeroxCollectionView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.edges.equalTo(self.view);
    }];
}

//: 懒加载数据模型数组
- (NSMutableArray *)prismXenonDatas {
	if (!_prismXenonDatas) {
		_prismXenonDatas = [NSMutableArray array];
	}
	return _prismXenonDatas;
}

#pragma mark - UICollectionView DataSource
- (NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section {
    return self.prismXenonDatas.count;
}

- (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath {
    KeyholeQuakeCell *opulentMelancholy = [collectionView dequeueReusableCellWithReuseIdentifier:NSStringFromClass([KeyholeQuakeCell class]) forIndexPath:indexPath];
    return opulentMelancholy;
}

#pragma mark - UICollectionView Delegate
- (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath {
    //: collectioncell 点击
}


@end
